//
//  GuiderNodeCell.m
//  ImGuider
//
//  Created by 李陆涛 on 2017/12/26.
//  Copyright © 2017年 imguider. All rights reserved.
//

#import "GuiderNodeCell.h"

@interface GuiderNodeCell ()

@property (weak, nonatomic) IBOutlet UILabel *guiderNameLabel;
@property (weak, nonatomic) IBOutlet UIImageView *guiderVipImageView;
@property (weak, nonatomic) IBOutlet UILabel *guiderTagLabel;
@property (weak, nonatomic) IBOutlet UILabel *guiderDescribeLabel;
@property (weak, nonatomic) IBOutlet UIImageView *guiderImageView;

@end

@implementation GuiderNodeCell

- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
    
    self.guiderImageView.layer.borderWidth = 1.0f;
    self.guiderImageView.layer.borderColor = kBGColor.CGColor;
}

- (void)setModel:(GuiderModel *)model {
    
    _model = model;
    
    self.guiderNameLabel.text = model.realname;
    self.guiderVipImageView.hidden = !model.vip;
    self.guiderTagLabel.text = model.certificate;
    self.guiderDescribeLabel.text = model.introduction;
    [self.guiderImageView setImageURL:[NSURL URLWithString:model.headimg] placeholderImage:[UIImage imageNamed:@"default"]];
}
@end

